import Vue from 'vue'
import Router from 'vue-router'
import Login from '@/components/Login'
import Home from '@/components/Home'
import GeneratorFormInner from '@/views/activity/innerModel/GeneratorFormInner'
import DrowProccessImageInner from '@/views/activity/innerModel/DrowProccessImageInner'
import ViewProcess from '@/views/activity/innerModel/ViewProcess'
import HighLightedProcessDiagram from '@/views/activity/innerModel/HighLightedProcessDiagram'
import TaskComment from '@/views/activity/innerModel/TaskComment'
import HistoricActivityInstance from '@/views/activity/innerModel/HistoricActivityInstance'
import HistoricDetail from '@/views/activity/innerModel/HistoricDetail'
import HistoricVariableInstance from '@/views/activity/innerModel/HistoricVariableInstance'
import PersonalCenter from '../components/userInfo/PersonalCenter.vue'
import ProcessHandlingPage from '@/views/activity/innerModel/ProcessHandlingPage'
import AuditPass from '@/views/activity/innerModel/auditProcess/AuditPass.vue'
import AuditBack from '@/views/activity/innerModel/auditProcess/AuditBack.vue'
import AuditDelegate from '@/views/activity/innerModel/auditProcess/AuditDelegate.vue'
import AuditTermination from '@/views/activity/innerModel/auditProcess/AuditTermination.vue'
import AuditOverrule from '@/views/activity/innerModel/auditProcess/AuditOverrule.vue'
import AuditTurn from '@/views/activity/innerModel/auditProcess/AuditTurn.vue'
import AuditFlow from '@/views/activity/innerModel/auditProcess/AuditFlow.vue'

Vue.use(Router)

export default new Router({
  // mode: 'history', // 去掉地址栏#
  routes: [
    {
      path: '/',
      name: 'Login',
      component: Login,
      hidden:true
    },
    {
      path: '/home',
      name: 'Home',
      component: Home,
      hidden:true,
      children:[
        {
          path: '/PersonalCenter',
          name: '个人中心',
          component: PersonalCenter,
          hidden:true
        },
        {
          path: '/generatorFormInner',
          name: '业务表设计',
          component: GeneratorFormInner,
          hidden:true
        },
        {
          path: '/drowProccessImageInner',
          name: '流程设计',
          component: DrowProccessImageInner,
          hidden:true
        },
        {
          path: '/viewProcess',
          name: '流程预览',
          component: ViewProcess,
          hidden:true
        },
        {
          path: '/HighLightedProcessDiagram',
          name: '流程实例跟踪',
          component: HighLightedProcessDiagram,
          hidden:true
        },
        {
          path: '/TaskComment',
          name: '任务详情',
          component: TaskComment,
          hidden:true
        },
        {
          path: '/HistoricActivityInstance',
          name: '节点执行历史',
          component: HistoricActivityInstance,
          hidden:true
        },
        {
          path: '/HistoricDetail',
          name: '流程节点详细历史',
          component: HistoricDetail,
          hidden:true
        },
        {
          path: '/HistoricVariableInstance',
          name: '流程实例变量历史',
          component: HistoricVariableInstance,
          hidden:true
        },
        {
          path: '/ProcessHandlingPage',
          name: '流程办理',
          component: ProcessHandlingPage,
          hidden:true
        },
        {
          path: '/AuditPass',
          name: '审批通过',
          component: AuditPass,
          hidden:true
        },
        {
          path: '/AuditFlow',
          name: '审批流转',
          component: AuditFlow,
          hidden:true
        },
        {
          path: '/AuditBack',
          name: '审批回退',
          component: AuditBack,
          hidden:true
        },
        {
          path: '/AuditDelegate',
          name: '审批委派',
          component: AuditDelegate,
          hidden:true
        },
        {
          path: '/AuditOverrule',
          name: '审批驳回',
          component: AuditOverrule,
          hidden:true
        },
        {
          path: '/AuditTermination',
          name: '审批终止',
          component: AuditTermination,
          hidden:true
        },
        {
          path: '/AuditTurn',
          name: '审批转办',
          component: AuditTurn,
          hidden:true
        }
    ]
    },
    {
      /*解决404问题*/
      path:'*',
      redirect:'/home'
    }
  ]
})
